package com.lovo.invoicing.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lovo.invoicing.bean.*;
import com.lovo.invoicing.bean.vo.OutGoodsBean;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface IGoodsService {
    IPage<GoodsBean> queryGoodsByPage(PageBean<GoodsBean> pageBean);

    IPage<OutGoodsBean> queryOutGoodsByPage(Page page, String goodsName,
                                             int goodsType);

    void addGoods(GoodsBean goodsBean);

    GoodsBean queryGoodsById(int goodsId);

    void updateBuyPrice(String goodsNo , double buyPrice);

    void updateSalePrice(int goodsId , int salePrice);


    void updateInventoryNo(String goodsNo , int inventoryNo);

    void reduceInventoryNo(String goodsNo,int outNo);

    GoodsBean queryGoodsByGoodsNo(String goodsNo);

    void outbound(SaleInfoBean saleInfoBean,int userId);

    void storage(BuyInfoBean buyInfoBean,int userId);
}
